import React from 'react'
import { useNavigate,useLocation } from 'react-router-dom';
import ButtonAuth from './components/buttonAuth'
import {Button} from 'antd';
export default function index(props) {
    const navigate = useNavigate();
    function addUser(){
        navigate('/NavPage/addUser')
    }
    const [btn,setBtn] = React.useState(<Button type='primary' onClick={addUser}>增加用户</Button>)
  return (
    <div>
      {React.cloneElement(props.children,{addUser,addC:'add_account',btn})} 
    </div>
  )
}
